package com.bjpowernode.controller;

import com.bjpowernode.domain.Type;
import com.bjpowernode.service.TypeService;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import javax.annotation.Resource;
import java.util.List;
@Controller
public class TypeController {
    @Resource
    private TypeService typeService;

    @RequestMapping("/selectType.do")
    @ResponseBody
    public List<Type> getType(){
        System.out.println("type");
        List<Type> type = typeService.findType();
        return type;
    }

}
